import React from 'react';
import FormBlock from './FormBlock';

const Form7 = props => {
    const {
        form,
        initialFormInfo: { talentCode, recruitTalentAwards = [] }
    } = props;
    const { required, ...otherProps } = props; // required为true和false判断走2套校验规则
    const formInfoList = [
        {
            label: '获奖时间',
            prop: 'awardTime',
            type: 'month'
        },
        {
            label: '奖项名称',
            prop: 'awardName',
            type: 'input'
        },
        {
            label: '颁发机构',
            prop: 'organize'
        }
    ];
    const blockProps = {
        ...otherProps,
        form,
        parentFieldData: recruitTalentAwards,
        parentField: 'recruitTalentAwards',
        formInfoList,
        titleText: '获奖记录',
        addButtonText: '+添加获奖记录',
        id: 'form7',
        talentCode
    };
    return <FormBlock {...blockProps} />;
};

export default Form7;
